package com.example.androidproject;

import com.example.androidproject.R;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class MainActivity extends Activity implements OnClickListener {

	private Button btnLogin, btnGo;
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        
        btnLogin = (Button) findViewById(R.id.btnLogin);
        btnLogin.setOnClickListener(this);
        
        btnGo = (Button) findViewById(R.id.btnGo);
        btnGo.setOnClickListener(this);
        
    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        getMenuInflater().inflate(R.menu.activity_main, menu);
        return true;
    }

	public void onClick(View v) {
		switch (v.getId()) {
		case R.id.btnLogin:
			startActivity(new Intent(this, LoginActivity.class));
			break;

		case R.id.btnGo:
			startActivity(new Intent(this, ScheduleActivity.class));
			break;

		default:
			break;
		}
	}
}
